Mixed Messages: Measuring Conformance and Non-Interference in TypeScript
نویسندگان
چکیده
TypeScript participates in the recent trend among programming languages to support gradual typing. The DefinitelyTyped Repository for TypeScript supplies type definitions for over 2000 popular JavaScript libraries. However, there is no guarantee that implementations conform to their corresponding declarations. We present a practical evaluation of gradual typing for TypeScript. We have developed a tool for use with TypeScript, based on the polymorphic blame calculus, for monitoring JavaScript libraries and TypeScript clients against the TypeScript definition. We apply our tool, TypeScript TPD, to those libraries in the DefinitelyTyped Repository which had adequate test code to use. Of the 122 libraries we checked, 62 had cases where either the library or its tests failed to conform to the declaration. Gradual typing should satisfy non-interference. Monitoring a program should never change its behaviour, except to raise a type error should a value not conform to its declared type. However, our experience also suggests serious technical concerns with the use of the JavaScript proxy mechanism for enforcing contracts. Of the 122 libraries we checked, 22 had cases where the library or its tests violated non-interference. 1998 ACM Subject Classification D.2.5 [Software Engineering]: Testing and Debugging
منابع مشابه
Mixed Messages: Measuring Conformance and Non-Interference in TypeScript (Artifact)
In the paper Mixed Messages: Measuring Conformance and Non-Interference in TypeScript we present our experiences of evaluating gradual typing using our tool TypeScript TPD. The tool, based on the polymorphic blame calculus, monitors JavaScript libraries and TypeScript clients against the corresponding TypeScript definition. Our experiments yield two conclusions. First, TypeScript definitions ar...
متن کاملIntroducing modified TypeScript in an exis ng framework to im - prove error handling
Error messages in compilers is a topic that is often overlooked. The quality of the messages can have a big impact on development time and ease of learning. Another method used to speed up development is to build a domainspecific language (DSL). This thesis migrates an existing framework to use TypeScript in order to speed up development time with compile-time error handling. Alternative method...
متن کاملComputational Modeling of 2-sided Message’s Effects on Perceived Argument Strength
The aim of this research is studying of 2-sided message’s effects on persuasiveness of anti-drug messages by computational modeling method. It’s been done for getting more effective and more persuasive messages. Persuasiveness of messages is measured be perceived argument strength of them which is determined by audiences. In this research, according to formative researches, a method for measuri...
متن کاملAchievable Secrecy Rate Regions of State Dependent Causal Cognitive Interference Channel
In this paper, the secrecy problem in the state dependent causal cognitive interference channel is studied. The channel state is non-causally known at the cognitive encoder. The message of the cognitive encoder must be kept secret from the primary receiver. We use a coding scheme which is a combination of compress-and-forward strategy with Marton coding, Gel’fand-Pinsker coding and Wyner’s wire...
متن کاملOn the Sum Rate of a 2 x 2 Interference Network
In an M × N interference network, there are M transmitters and N receivers with each transmitter having independent messages for each of the 2 −1 possible non-empty subsets of the receivers. We consider the 2 × 2 interference network with 6 possible messages, of which the 2 × 2 interference channel and X channel are special cases obtained by using only 2 and 4 messages respectively. Starting fr...
متن کاملذخیره در منابع من
با ذخیره ی این منبع در منابع من، دسترسی به آن را برای استفاده های بعدی آسان تر کنید
عنوان ژورنال:
دوره شماره
صفحات -
تاریخ انتشار 2017